import VueRouter from 'vue-router'
import account from '../components/Account.vue'
import goodslist from '../components/GoodsList.vue'
import login from '../components/Login.vue'
import register from '../components/Register.vue'

// 创建路由对象
var routerObj = new VueRouter({
    routes: [{
            path: '/account',
            component: account,
            children: [
                { path: 'login', component: login },
                { path: 'register', component: register }
            ]
        },
        { path: '/goodslist', component: goodslist }
    ]
})

export default routerObj